package com.hsjk.szwj.module.pay.service;

import com.hsjk.szwj.module.pay.util.ChannelCertConfigKitBean;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Value;

import javax.annotation.Resource;

/**
 * @author chenjiawei
 * @desc 退款接口抽象类
 * @Date 2023/08/25 00:04
 **/
public abstract class AbstractRefundService implements IRefundService {
    //    @Resource
//    protected SysConfigService sysConfigService;
    @Resource
    protected ChannelCertConfigKitBean channelCertConfigKitBean;
    @Resource
    protected ConfigContextQueryService configContextQueryService;

    @Value("${szwj.pay.base-url}")
    private String payBaseUrl;

    protected String getNotifyUrl() {
        return payBaseUrl + "/api/refund/notify/" + getIfCode();
    }

    protected String getNotifyUrl(Long refundOrderId) {
        return payBaseUrl + "/api/refund/notify/" + getIfCode() + "/" + refundOrderId;
    }
}
